<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <title>自定义登录页</title>
    <link rel="stylesheet" href="/cas/themes/mylogin/css/bootstrap.min.css">
</head>
<body>
<div class="container mt-4">
    <form th:object="${credential}" action="login" method="post">
        <div class="form-group">
            <label for="username">用户：</label>
            <input type="text" class="form-control" th:field="*{username}" placeholder="请输入用户" required>
        </div>
        <div class="form-group">
            <label for="password">密码：</label>
            <input type="text" class="form-control" th:field="*{password}" placeholder="请输入密码" required>
        </div>
		<div class="form-group" th:if="${#fields.hasErrors('*')}">
			<span th:each="err : ${#fields.errors('*')}" th:utext="${err}"></span>
		</div>
		<input type="hidden" name="execution" th:value="${flowExecutionKey}"/>
		<input type="hidden" name="_eventId" value="submit"/>
		<input type="hidden" name="geolocation"/>

        <button type="submit" class="btn btn-primary">登录</button>
    </form>
</div>
<script src="/cas/themes/mylogin/js/jquery-3.5.1.min.js"></script>
<script src="/cas/themes/mylogin/js/bootstrap.bundle.min.js"></script>
</body>
</html>